package com.tbit.uqbike.webmanager.controller;

import com.tbit.uqbike.object.view.FollowDTO;
import com.tbit.common.entity.view.Result;
import com.tbit.uqbike.service.business.SensitivenessService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author LHX
 * @Date 2023/11/16 10:01
 */
@RestController
@RequestMapping("/sensitiveness")
public class SensitivenessController {

	@Autowired
	private SensitivenessService sensitivenessService;


	/**
	 * 1：关注 2：取消关注
	 * @return String
	 */
	@PostMapping("/follow")
	public Result<String> follow(@RequestBody FollowDTO followDTO) {
		return sensitivenessService.follow(followDTO);
	}


	/**
	 * 是否关注
	 * @param followDTO
	 * @return
	 */
	@PostMapping("/getSens")
	public Result<Boolean> getSens(@RequestBody FollowDTO followDTO){
		return sensitivenessService.getSens(followDTO);
	}

}
